package cn.tedu.oa_system.pojo;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.Objects;

/**
 * @Author MW
 * @Description 用户实体类
 * @CreateDate 2023/1/6
 */
@TableName(value = "user")
@Data
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId
    private Long userId;

    private String address;

    private String bank;

    private Date birth;

    private String email;

    private Long fatherId;

    private Date hireTime;

    private String userIdcard;

    private String imgPath;

    private Integer isLock;

    private String lastLoginIp;

    private Date lastLoginTime;

    private Date modifyTime;

    private Long modifyUserId;

    private String password;

    private String realName;

    private Float salary;

    private String userSchool;

    private String sex;

    private String themeSkin;

    private String userEdu;

    private String userName;

    private String userSign;

    private String userTel;

    private Long deptId;

    private Long positionId;

    private Long roleId;

    private Integer superman;

    private Integer holiday;

    private String pinyin;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        User user = (User) o;
        return Objects.equals(userId, user.userId) && Objects.equals(address, user.address) && Objects.equals(bank, user.bank) && Objects.equals(birth, user.birth) && Objects.equals(email, user.email) && Objects.equals(fatherId, user.fatherId) && Objects.equals(hireTime, user.hireTime) && Objects.equals(userIdcard, user.userIdcard) && Objects.equals(imgPath, user.imgPath) && Objects.equals(isLock, user.isLock) && Objects.equals(lastLoginIp, user.lastLoginIp) && Objects.equals(lastLoginTime, user.lastLoginTime) && Objects.equals(modifyTime, user.modifyTime) && Objects.equals(modifyUserId, user.modifyUserId) && Objects.equals(password, user.password) && Objects.equals(realName, user.realName) && Objects.equals(salary, user.salary) && Objects.equals(userSchool, user.userSchool) && Objects.equals(sex, user.sex) && Objects.equals(themeSkin, user.themeSkin) && Objects.equals(userEdu, user.userEdu) && Objects.equals(userName, user.userName) && Objects.equals(userSign, user.userSign) && Objects.equals(userTel, user.userTel) && Objects.equals(deptId, user.deptId) && Objects.equals(positionId, user.positionId) && Objects.equals(roleId, user.roleId) && Objects.equals(superman, user.superman) && Objects.equals(holiday, user.holiday) && Objects.equals(pinyin, user.pinyin);
    }

    @Override
    public int hashCode() {
        return Objects.hash(userId, address, bank, birth, email, fatherId, hireTime, userIdcard, imgPath, isLock, lastLoginIp, lastLoginTime, modifyTime, modifyUserId, password, realName, salary, userSchool, sex, themeSkin, userEdu, userName, userSign, userTel, deptId, positionId, roleId, superman, holiday, pinyin);
    }

    @Override
    public String toString() {
        return "User{" +
                "userId=" + userId +
                ", address='" + address + '\'' +
                ", bank='" + bank + '\'' +
                ", birth=" + birth +
                ", email='" + email + '\'' +
                ", fatherId=" + fatherId +
                ", hireTime=" + hireTime +
                ", userIdcard='" + userIdcard + '\'' +
                ", imgPath='" + imgPath + '\'' +
                ", isLock=" + isLock +
                ", lastLoginIp='" + lastLoginIp + '\'' +
                ", lastLoginTime=" + lastLoginTime +
                ", modifyTime=" + modifyTime +
                ", modifyUserId=" + modifyUserId +
                ", password='" + password + '\'' +
                ", realName='" + realName + '\'' +
                ", salary=" + salary +
                ", userSchool='" + userSchool + '\'' +
                ", sex='" + sex + '\'' +
                ", themeSkin='" + themeSkin + '\'' +
                ", userEdu='" + userEdu + '\'' +
                ", userName='" + userName + '\'' +
                ", userSign='" + userSign + '\'' +
                ", userTel='" + userTel + '\'' +
                ", deptId=" + deptId +
                ", positionId=" + positionId +
                ", roleId=" + roleId +
                ", superman=" + superman +
                ", holiday=" + holiday +
                ", pinyin='" + pinyin + '\'' +
                '}';
    }
}
